home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / edit / aurora2.zip / TIPS.DOX < prev    next >
Text File  |  1995-01-26  |  17KB  |  411 lines

  1.  
  2.  
  3. Miscellaneous Aurora User Tips
  4. ──────────────────────────────
  5. This file contains a few miscellaneous Aurora user tips which you may
  6. wish to review. For complete documentation on how to install and use
  7. Aurora, see the Aurora Editor Users Guide (USER.DOX). Note that any key
  8. definitions shown here are the Aurora-style defaults.
  9.  
  10.  
  11. Basic Configuration
  12. ───────────────────
  13.  ∙ The editor should always be installed in an empty directory. Never
  14.    mix files from different editor versions.
  15.  
  16.  ∙ Whenever you make a change to any of the editor configuration files
  17.    (such as CONFIG.AML, KBD.AML, MENU.AML, etc.), you must enter the
  18.    'recompile' command ('Recompile the editor' <alt f2> on the Set menu)
  19.    for your changes to take effect.
  20.  
  21.  ∙ If you prefer to start Aurora by another name, you can simply rename
  22.    the file A.EXE to whatever you wish (such as E.EXE). Do not rename
  23.    any other files distributed with the editor.
  24.  
  25.  ∙ You can re-install Aurora by selecting 'Run installation' from the
  26.    Sample Utilities Macros menu (on the Macro menu).
  27.  
  28.  
  29. The Keyboard
  30. ────────────
  31.  ∙ When adding new key definitions to KBD.AML, be sure to place each
  32.    definition in the appropriate 'object' for the window in which you
  33.    would like the key to be active.
  34.  
  35.  ∙ If you have added or changed keyboard definitions, you will probably
  36.    also want to change any Menu definitions which show the old keys.
  37.  
  38.  ∙ To prevent the editor from using the keypad <grey />, <grey *>, <grey
  39.    ->, and <grey +> keys as function keys, simply remove these function
  40.    key definitions from KBD.AML. Be sure to remove them from within both
  41.    the 'prompt' and 'edit' objects.
  42.  
  43.  ∙ To execute a key or macro function from the DOS command line, use the
  44.    '-e' command line option. Key or event names must be enclosed in
  45.    double quotes. For example:
  46.  
  47.      C>a -emymacro
  48.         // executes the function 'mymacro' after the editor is started
  49.  
  50.      C>a -e"<shift f1>" -e"<alt =>"
  51.         // simulates <shift f1>, <alt => after the editor is started
  52.  
  53.  ∙ New keyboard layouts for other editors/word processors may be added
  54.    periodically to the Aurora Support BBS (see READ.ME for access
  55.    details). Check the BBS if your favorite layout is not included in
  56.    the distributed version of Aurora.
  57.  
  58.  
  59. The Mouse
  60. ─────────
  61.  ∙ If windows scroll too fast when using the mouse, change the
  62.    'MouDelay' setting in CONFIG.AML to a higher value.
  63.  
  64.  ∙ To hide the mouse pointer whenever a key pressed, change the
  65.    'MouseOpt' setting in CONFIG.AML to 'd'.
  66.  
  67.  
  68. The Menus
  69. ─────────
  70.  ∙ If part of a pull-down menu is displayed off the edge of the screen,
  71.    you can use the mouse to grab the menu border and drag the menu to a
  72.    better position.
  73.  
  74.  ∙ To hide the menu bar so that it is only displayed when <esc> or the
  75.    right mouse button is pressed, remove 'm' from the 'EditStyle'
  76.    setting in CONFIG.AML.
  77.  
  78.  ∙ To jump quickly to a file within a file picklist or the file manager,
  79.    enter the first letter of the desired filename repeatedly until the
  80.    cursor is positioned at the file.
  81.  
  82.  
  83. Prompts
  84. ───────
  85.  ∙ The Ascii Chart <alt => can be displayed from within a prompt and
  86.    used to enter any character. The 'literal' <ctrl [> command can also
  87.    be used to enter any character in a prompt.
  88.  
  89.  ∙ Use <pgup> or <pgdn> within a prompt, or press the left mouse button
  90.    on the retrieve tab () to display a popup menu of all prompt
  91.    history. You can enter a history string into the prompt by pressing
  92.    the <enter> key or the left mouse button.
  93.  
  94.  ∙ Use the 'Prompt Style' command on the Window menu to sample the four
  95.    editor prompt styles. To change the default prompt style when the
  96.    editor is started, see the 'PromptStyle' configuration setting in
  97.    CONFIG.AML.
  98.  
  99.  ∙ To move the cursor a relative number of lines away from the current
  100.    position in the 'goto line' <ctrl j> prompt, specify '+' or '-'
  101.    before the line number.
  102.  
  103.  ∙ The 'Macro Expression' prompt <ctrl v> on the Macro menu can be used
  104.    as a command line calculator, since the macro language compiler and
  105.    interpreter are available at this prompt. For example:
  106.  
  107.      Macro Expression>  say 1 + 2 + 30 - 40    <enter>  // displays -7
  108.      Macro Expression>  msgbox (4 * 15) mod 7  <enter>  // displays 4
  109.  
  110.  
  111. The Desktop
  112. ───────────
  113.  ∙ You can prevent windows from remembering their sizes, cursor
  114.    positions, and settings by changing the 'SavePosition' setting in
  115.    CONFIG.AML to 'n'.
  116.  
  117.  ∙ To use the existing DOS screen as the editor background when the
  118.    editor is started, change the 'VidStr' setting in CONFIG.AML to ''
  119.    (null).
  120.  
  121.  ∙ If your video card supports special video modes such as 132 x 43, you
  122.    can use these video modes within the editor by setting the 'VidCols'
  123.    and 'VidRows' in CONFIG.AML to zero. Then set the desired video mode
  124.    in DOS before starting the editor.
  125.  
  126.  ∙ Use the 'showentry' command to display the screen as it appeared in
  127.    DOS before the editor was started.
  128.  
  129.  
  130. Syntax Highlighting
  131. ───────────────────
  132.  ∙ To conserve editor resources, include only the syntax highlighting
  133.    definitions in SYNTAX.AML that you actually use.
  134.  
  135.  ∙ Additional syntax highlighting definitions are containing in the file
  136.    SYNTAX2.AML.
  137.  
  138.  ∙ If you are using syntax highlighting with multi-line comments in your
  139.    program source code, you may wish to increase the number of lines to
  140.    scan backward in SYNTAX.AML, for the file extension you are editing.
  141.    Note however, that this will decrease scrolling performance for
  142.    highlighted files.
  143.  
  144.  ∙ The 'hiliteword' <ctrl \> command highlights all occurrences of the
  145.    word at the cursor. This can be very useful for finding instances of
  146.    a word in a document, or marking occurrences of variables, functions,
  147.    or other identifiers in your program source code.
  148.  
  149.  ∙ Individual keywords can be highlighted in colors different from the
  150.    default keyword color by treating the keyword as an object variable
  151.    and assigning it the desired color attribute. For example, in
  152.    SYNTAX.AML:
  153.  
  154.      keyword
  155.        .
  156.        .      // end of keyword list
  157.  
  158.      _if   = color brightred on blue
  159.      _else = color yellow    on blue
  160.  
  161.  
  162. History
  163. ───────
  164.  ∙ To erase all of your existing history prompts, window positions,
  165.    etc., simply delete HISTORY.DAT after you have exited the editor.
  166.  
  167.  ∙ Do not attempt to manually update the history file HISTORY.DAT. This
  168.    file is automatically updated by the editor during normal usage.
  169.  
  170.  
  171. Opening Files
  172. ─────────────
  173.  ∙ To open a file manager window for the current directory from the DOS
  174.    command line, enter "a .".
  175.  
  176.  ∙ To open a file from the DOS command line and place the cursor on a
  177.    specific line, enter the option 'l' followed by the line number. For
  178.    example:
  179.  
  180.      C>a myfile.txt/l253
  181.        // opens 'myfile.txt' and places the cursor on line 253
  182.  
  183.  ∙ To open a binary file from the DOS command line or the Open prompt
  184.    ('askopen' <alt e> on the File menu) using a specific line length,
  185.    enter the option 'b' followed by the line length. For example:
  186.  
  187.      C>a myfile.txt/b240
  188.        // opens 'myfile.txt' in binary mode with a fixed line length
  189.        //   of 240
  190.  
  191.  ∙ To configure the editor so that tab characters (ascii 9) are
  192.    automatically expanded when files are opened, see example 21 of
  193.    EXAMPLE.AML in the MACRO subdirectory.
  194.  
  195.  ∙ If you are using Aurora in an MS Windows 3.x DOS box running in
  196.    enhanced mode, you can transfer up to 16k of text data to and from
  197.    the Windows clipboard. This is done by loading from or saving to a
  198.    file with the special drive name: ^. For example, from the Open and
  199.    Insert and Save block prompts:
  200.  
  201.      File to insert in MYFILE.TXT>  ^:c
  202.        // insert the contents of the Windows clipboard after the cursor
  203.  
  204.      Save block as> ^:c
  205.        // copy marked text to the Windows clipboard
  206.  
  207.  
  208. Searching
  209. ─────────
  210.  ∙ Frequently-used search strings can be saved in a separate file and
  211.    copied to a find prompt as needed by using the 'copyblock2' <alt c>
  212.    or 'paste' <grey*> commands. This can be especially convenient for
  213.    long or complex regular expression patterns.
  214.  
  215.  ∙ To count the occurrences of a search string, use the 'a' search
  216.    option. For example:
  217.  
  218.      Find>  gismo/a  <enter>
  219.        // displays the number of occurrences of the word 'gismo'
  220.        //   from the cursor to the end of the file
  221.  
  222.  ∙ Use regular expression searching to search for the beginning and/or
  223.    end of lines. Do not attempt to search for line delimiter characters
  224.    (such as carriage returns and linefeeds) in non-binary files. In the
  225.    normal, non-binary editing mode, line delimiter characters are
  226.    removed from the end of each line when the file is loaded and
  227.    re-appended to the end of each line when the file is saved.
  228.  
  229.  ∙ The 'Find Occurrences' <ctrl h> command can be useful for extracting
  230.    lines from a flat database file that match search criteria. For
  231.    example:
  232.  
  233.      Find Occurrences of>  Joe/b
  234.        // extract all lines where 'Joe' is found within a column mark
  235.  
  236.  ∙ The 'Find Occurrences' <ctrl h> command can be used together with
  237.    regular expression searching to display a list of function headers in
  238.    your program source code. For example:
  239.  
  240.      Find Occurrences of>  ^[a-zA-Z_].*\(.*[~;]$/x
  241.        // finds C/C++ function definitions beginning in column 1
  242.  
  243.      Find Occurrences of>  ^ *{function}|{key}.*$/x
  244.        // finds AML function and key definitions
  245.  
  246.  ∙ Selecting a file from a file manager scan window (generated by the
  247.    'askscan' <ctrl s> command) will position the cursor to the first
  248.    occurrence of the scan search string. Use the 'findlast' <ctrl l>
  249.    command to find other occurrences.
  250.  
  251.  
  252. Manipulating Text
  253. ─────────────────
  254.  ∙ The 'quote' <shift f9> and 'commentline' <alt f1> commands can both
  255.    be used for simple text quoting. <shift f9> performs block quoting,
  256.    while <alt f1> quotes and unquotes text on a line-by-line basis.
  257.  
  258.  ∙ The editor is configured at installation to use 'live word wrap' when
  259.    <ctrl w> is pressed. If you prefer the standard old-style word wrap,
  260.    change the definition of <ctrl w> in KBD.AML to:
  261.  
  262.      key  <ctrl w>    setting 'W' TOGGLE   // toggle standard word wrap
  263.  
  264.  ∙ To reformat all of the text in a file, mark the entire file using the
  265.    'markline' <alt l> command, and then enter the 'Reformat' command
  266.    <alt r> on the Block menu.
  267.  
  268.  ∙ The 'fillblock2' <ctrl k><f> command can be used to fill a marked
  269.    block with a repeating character or string. For example: to fill
  270.    columns 40-47 of a data file with the date 12/25/96, mark the
  271.    desired columns by using the 'markcolumn' command <ctrl b>, and then
  272.    enter the date at the 'fillblock2' prompt.
  273.  
  274.  ∙ The clipboard Cut Append <ctrl grey-> and Copy Append <ctrl grey+>
  275.    commands can be very useful for gathering separate blocks of text and
  276.    grouping them together in the clipboard.
  277.  
  278.  ∙ To expand tab characters (ascii 9) in the current file, use the
  279.    'tabfile' <ctrl k><x> command.
  280.  
  281.  ∙ To ignore case when sorting marked text with the 'sortblock2' <ctrl
  282.    k><o> command, turn insert mode ON. To sort in descending order, turn
  283.    scroll lock ON.
  284.  
  285.  ∙ Have you ever been prompted to save changes in a file, and you forgot
  286.    what changes you just made? Try using the undo/redo feature to review
  287.    your changes. Just cancel the 'save' prompt and use the undo <ctrl u>
  288.    and redo <ctrl y> commands to backtrack and retrace your changes
  289.    before exiting.
  290.  
  291.  ∙ To the change the line delimiter that a file is saved with, load the
  292.    file into the editor, change the current 'Line Delimiter' setting (on
  293.    the Set menu) to the new line delimiter, and save the file.
  294.  
  295.  ∙ To disable CUA-style <shift> key marking, remove the 'smark' command
  296.    from all key definitions in KBD.AML.
  297.  
  298.  ∙ Use the 'markpara' <alt 3> command to quickly mark the paragraph at
  299.    the cursor.
  300.  
  301.  ∙ To rearrange all the words in a paragraph in sorted order:
  302.  
  303.      1. Use the 'markcolumn' <alt b> command to mark column 1 of the
  304.         entire paragraph.
  305.      2. Enter the 'formatblock2' command <alt r> to place each word on
  306.         separate line.
  307.      3. Enter the 'markpara' <alt 3> command to re-mark the separated
  308.         paragraph with a line mark.
  309.      4. Set Insert mode ON to ignore case during the sort.
  310.      5. Enter the 'sortblock2' <ctrl k><o> command to sort the words.
  311.      6. Enter the 'formatblock2' command <alt r> to re-join all
  312.         separated lines back together into a paragraph.
  313.  
  314.  
  315. Working with very large files
  316. ─────────────────────────────
  317.  ∙ If you are performing extensive 'search and replace all' operations
  318.    in a very large file, or you are making other large-scale
  319.    modifications to the file, you will get better performance if 'Undo'
  320.    is disabled on the Set menu.
  321.  
  322.  ∙ Aurora can be useful for editing very large files when running under
  323.    OS/2 or Windows. Although other editors may exploit the virtual
  324.    memory capabilities of these environments, Aurora uses its own
  325.    virtual memory (optimized for text editing), and will not force other
  326.    OS/2 or Windows applications to be swapped out or discarded when very
  327.    large files are loaded and edited. The 'memoptions' setting in
  328.    SYSTEM.AML should be set to 'o' for the best performance.
  329.  
  330.  ∙ Setting 'memoptions' to 'o' in SYSTEM.AML allows large files to be
  331.    kept open (in DOS) while they are being edited. This feature can
  332.    greatly increase the loading performance for very large files.
  333.    However, in some cases there may be conflicts with other programs
  334.    trying to access the open file. If this is a problem for you, set
  335.    'memoptions' to '' (null).
  336.  
  337.  ∙ Before saving changes to very large files, you may wish to conserve
  338.    disk space by disabling file 'Backup' on the Set menu. Obviously,
  339.    this should only be done if you have backup files elsewhere.
  340.  
  341.  ∙ If you only need to browse the first part of a very large file, or if
  342.    you have started loading a very large file by mistake, you can press
  343.    <ctrl break> to interrupt the loading process at any point. Note that
  344.    the loaded file will be truncated, and you will be prompted with
  345.    "Truncated file - are you sure?" whenever you try to save the file.
  346.  
  347.  
  348. AML Macros
  349. ──────────
  350.  ∙ To obtain context-sensitive help on a macro language statement or
  351.    function at the cursor, press <shift f1> for a brief description, or
  352.    press <shift f2> for extended help. Note that most extension
  353.    functions (EXT.AML source code) are not documented. For these
  354.    functions, the cursor is moved to the function definition in EXT.AML.
  355.  
  356.  ∙ To compile and run an external macro in the current edit window, just
  357.    enter the 'compilemacro2' <shift f10> and 'runmacro2' <shift f11>
  358.    commands. These commands help to simplify macro development and
  359.    testing.
  360.  
  361.  ∙ You can use the 'pickmacro' <shift f12> command to obtain a picklist
  362.    of macros in the MACRO subdirectory. To run a macro from the
  363.    picklist, move the cursor to the desired macro and press the <enter>
  364.    key or click the left mouse button.
  365.  
  366.  ∙ Whenever you modify any internal macro code (EXT.AML, KBD.AML, etc.),
  367.    be sure to make backup copies of your AML files. You should be
  368.    reasonably familiar with the macro language before attempting these
  369.    types of modifications.
  370.  
  371.  ∙ AML has a simpler function call syntax than most programming
  372.    languages. Here are a few things to keep in mind when calling AML
  373.    functions:
  374.  
  375.    If function calls with arguments are used in expressions, the entire
  376.    function call should be enclosed with parentheses, not just the
  377.    arguments. For example:
  378.  
  379.      x = fun1 (1) + fun2 (2, 3, 4);    // BASIC, Pascal, C
  380.      x = (fun1 1) + (fun2 2 3 4)       // AML
  381.  
  382.    Function calls which have no arguments, and which are preceded or
  383.    followed by operators, do not need parentheses:
  384.  
  385.      x = fun1 () + fun2 ();     // BASIC, Pascal, C
  386.      x = fun1 + fun2            // AML
  387.  
  388.    If a single function call is an argument to another function, and is
  389.    not preceded or followed by an operator, then it must be enclosed in
  390.    parentheses. For example:
  391.  
  392.      x = fun1 (1, fun2 (), fun3 (2, 3, 4));   // BASIC, Pascal, C
  393.      x = fun1 1 (fun2) (fun3 2 3 4)           // AML
  394.  
  395.  ∙ The 'key' statement is terminated by the keywords 'end', 'key', or
  396.    'function', but not by the keyword 'object'. For example:
  397.  
  398.      key <alt c>   copy          // key definition for <alt c>
  399.      key <alt d>   deleteline    // key definition for <alt d>
  400.      end                         // end is required here
  401.  
  402.      object  fmgr                // change the current object
  403.        .
  404.        .
  405.  
  406.  ∙ New macros and AML configuration files will continue to be posted on
  407.    the Aurora Support BBS (see READ.ME for access details). Many of
  408.    these macros may only be available to licensed users. You may wish to
  409.    check the BBS periodically for new macros.
  410.  
  411.